package com.lzy.cloud.order.remote;

import com.lzy.cloud.order.remote.request.CarCalendarRequest;
import com.lzy.framework.core.output.Result;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

/**
 * @Description: 商品服务接口
 * @Author:   gyl
 * @Date:     2018/7/10 9:51
 */
@FeignClient(name = "lzy-cloud-goods")
public interface GoodsApi {

    /**
     * 方法说明：根绝条件查询商品详情
     * @param   id
     * @return
     * @date        2018/7/10 9:52
     */
    @RequestMapping(value = "/goods/find/{mode}/{id}")
    Result selectById(@PathVariable("mode") Integer mode, @PathVariable("id") Long id);

    /**
     * 方法说明：根绝条件查询房车销售
     * @param   id
     * @return
     * @date        2018/7/10 9:52
     */
    @RequestMapping(value = "/goods/car/sale/detail/{id}")
    Result selectByCarSaleId(@PathVariable("id") Long id);

    /**
     * 释放档期
     * @param request
     * @return
     */
    @RequestMapping(value = "/car/calendar/release",method = RequestMethod.POST)
    Result releaseCalendar(CarCalendarRequest request);
}
